<link href="/resource/css/admin/system/dialog/checkflowtrack.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="/resource/js/admin/system/dialog/checkflowtrack.js"></script>
<div class="head" onmousedown="dialogheadclickdown(this)" onmouseup="dialogheadclickup()">
	流程跟踪<a onclick="dialogclose()"></a>
</div>
<div class="body">
	<div class="bodycontent">
		<table cellpadding="4" cellspacing="1">
			<tr>
				<td width="120" align="center" valign="top">
					<div class="checkrecordtd">
						<#assign before = true>
						<#list checknodes as checknode>
							<#assign color ="">
							<#if article.articleState.id == 2>
								<#if before>
									<#assign color = "red">
	             					<#assign before = false>
								<#else>
	                				<#assign color = "gray">
								</#if>
							<#else>
								<#if before>
									<#assign color = "green">
									<#if article.checknode?? && checknode.id == article.checknode.id>
										<#assign color = "red">
										<#assign before = false>
									</#if>
								<#else>
									<#assign color = "gray">
								</#if>
							</#if>
							<div class="checknodes" style="color:${color};<#if color == 'red'>font-weight:bold;</#if>">${checknode.name}</div>
							↓
						</#list>
						<div class="checknodes" style="color:${(article.articleState.id == 4)?string('green','gray')}">发布</div>
					</div>
				</td>
				<td valign="top">
					<div class="checkrecordtd">
		               	<#list checkrecords as checkrecord>
							${checkrecord.submittime?string('yyyy-MM-dd HH:mm:ss')}
		               		<#if checkrecord.checknode??>[${checkrecord.checknode.name}]</#if><br />
		               		${checkrecord.admin.name}[${checkrecord.admin.department.name}]
		               		<#if checkrecord.checkrecordResult??>
		               			<span style="color:${checkrecord.checkrecordResult.color}">${checkrecord.checkrecordResult.name}</span><#if checkrecord.checkrecordResult.separate??>${checkrecord.checkrecordResult.separate?trim}</#if>
		               		</#if>
		               		${checkrecord.opinion!}<hr class="dashedstyle" />
		               	</#list>
		               	<#if article.checknode??>
		               		等待<span style="color:red">${article.checknode.name}</span>${article.checknode.singleaudit?string("单审","会审")}
		               		<#assign accounts1 = "">
		               		<#assign accounts2 = "">
		               		<#assign accountsall = "">
		               		<#list article.checknode.checknodeReAdmins as cnra>
		               			<#if !article.checknode.groupbydepart || article.admin.department.id == cnra.admin.department.id>
		               				<#if !huicheckadminids?? || huicheckadminids?size == 0 || huicheckadminids?size gt 0 && !huicheckadminids?seq_contains(cnra.admin.id)>
		               					<#assign accounts1 = accounts1 + cnra.admin.name + " ">
		               				<#else>
		               					<#assign accounts2 = accounts2 + "<span style='color:green'>" + cnra.admin.name + "√</span> ">
		               				</#if>
		               			</#if>
		               		</#list>
		               		<#assign accountsall = accountsall + accounts1>
		               		<#if accounts2 != "">
		               			<#if accountsall != ""><#assign accountsall = accountsall + "<br />"></#if>
		               			<#assign accountsall = accountsall + accounts2>
		               		</#if>
		               		<div class="checkernames">${accountsall}</div>
		               	<#else>
		       				<#if article.articleState.id == 4>
		       					<div class="checkresult checksuccess"><img src="/resource/image/admin/main/system/dialog/success.gif" /><br />文档已发布</div>
		       				<#else>
		       					<div class="checkresult checkfail"><img src="/resource/image/admin/main/system/dialog/fail.gif" /><br />文档已驳回</div>
		       				</#if>
		               	</#if>
	               </div>
				</td>
			</tr>
		</table>
    </div>
</div>
<div class="buttonpanel">
	<div class="buttoncontext">
        <a onclick="dialogclose()">关闭</a>
    </div>
</div>